<template>
  <div class="tableList">
    <div class="add">
      <p>{{title+"人员调整记录"}}</p>
    </div>
    <div>
      <base-table :tableSetting="tableConfig"></base-table>
    </div>
  </div>
</template>
<script>
export default {
  props:{
    tableData:{
      type:Array,
      default:()=>{
        return []
      }
    },
    title:{
      type:String,
      default:""
    }
  },
  data() {
    return {
      tableConfig: {
        indexShow: true,
        highlightRow: false,
        column: [
          {
            label: "调整时间",
            textAlign: "center",
            prop: "adjustTime",
          },
          {
            label: "调整前",
            textAlign: "center",
            prop: "beforeStaff",
          },
          {
            label: "调整后",
            textAlign: "center",
            prop: "afterStaff",
          },
          {
            label: "调整原因",
            textAlign: "center",
            prop: "cause",
          }
        ],
        data: [],
        noBorderRight: false,
        autoHeight: true,
        //height: 400,
      },
    };
  },
  watch:{
    tableData:{
      handler(val){
        this.tableConfig.data = val;
      }
    }
  },
  methods: {
  },
};
</script>
<style lang="less" scoped>
.tableList {
  width: 100%;
  height: 100%;
  .add{
    text-align: left;
  }
}
</style>